package com.bianguo.android.tencentpushdemo.utils;

import java.text.Collator;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.List;
import java.util.Locale;

/**
 * Created by Administrator on 2017/4/12.
 */

public class SortUtil {

    public static List<String> sortByLetter(ArrayList<String> list){
        Comparator comparator = Collator.getInstance(Locale.CHINA);
        String[] strings = list.toArray(new String[list.size()]);
        Arrays.sort(strings, comparator);
        return Arrays.asList(strings);
    }
}
